package imread;





public class test {

    
    public static void main(String[] args) throws Exception {  
    //	System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/qs/v1/shelf/add", "book_id=45"));

    //	System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/group/page", "group_id=1"));
    	/* String inputStr = "1738824869266432123456";  
         String key = IReadContent.dec_password;
         System.err.println("原文:\t" + inputStr);  
   
         System.err.println("密钥:\t" + key);  
   
         byte[] inputData = inputStr.getBytes();  
         inputData = DESCoder.encrypt(inputData, key);  
        String sign  = DESCoder.encryptBASE64(inputData);
        System.out.println(sign);
         System.err.println("加密后:\t" +URLEncoder.encode(DESCoder.encryptBASE64(inputData),"UTF-8"));  
   
         byte[] outputData = DESCoder.decrypt(DESCoder.decryptBASE64(sign), key);  
         String outputStr = new String(outputData);  
   
         System.err.println("解密后:\t" + outputStr);  */
   
        // assertEquals(inputStr, outputStr);  
   
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/qs/v1/me",""));
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/qs/v1/auth/check/sign", "sign=s0hIalRFyZEN9SvB%2Fgw3%2Fz3gP5D%2B0qjV%0D%0A"));
    //	System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/qs/v1/auth/reset/email", "email=243147254@qq.com"));
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/qs/v1/auth/reset/email", "email=fisher.fujun@gmail.com"));

    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/qs/v1/auth/login/sso", "user_identifier=123456&device_identifier=1qaa&nick_name=1141&source=2&promot=qs&img_url=1213as"));

    	//System.out.println(HttpRequestUtil.sendPost("http://101.200.191.41:9090/qs/v1/auth/login/custom", "user_name=勤书网&password=iqinshu%zdcm3"));

    	//System.out.println(HttpRequestUtil.sendPost("http://101.200.191.41:9090/qs/v1/auth/register", "user_name=xsk243147254&password=123456&device_identifier=123456&promot=qs&email=345385729@qq.com"));
		
    	
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/file/download/1/1","phone=15869155962&key=123456"));

    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/v1/pay","mobileNum=15088601783&productId=1"));

    	//1
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/page/content","page_id=11&pages=1&blocks=100"));

    	//1System.out.println(HttpRequestUtil.sendPost("http://wap.cmread.com/r/p/viewdata.jsp","bid=350743903&vt=9"));
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.253:8080/api/bookMark/list","book_id=77903&contents=20&pages=1"));
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.253:8080/api/bookMark/list","contents=20&pages=1"));
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.253:8080/api/bookSheet/list/user","contents=20&pages=1"));
    	
    	
    	//   	System.out.println(HttpRequestUtil.sendGet("http://readapi.imread.com/api/page/content","page_id=9&pages=1&blocks=100"));
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/book/intercut/list","bid=388301&page=10"));
    	
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/book/intercut/list","bid=388301&page=10"));
    	//System.out.println(HttpRequestUtil.sendGet("http://readapi.imread.com/api/book/intercut/list","bid=388301&page=10"));

    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.34:9090/api/book/chapterlist","bid=390157&page=25&page_size=2&vt=9&order_type=asc"));

    	/*String readLog = "[{\"current_chapterid\":\"\",\"chapter_offset\":0,\"charge_type\":2,\"chapter_id\":\"16444\",\"source_id\":3,\"current_time\":\"\",\"spm\":0,\"source_content_id\":138,\"charge_fee\":\"0.08\",\"read_time\":\"20160118172128\",\"chapter_read_time\":1979,\"content_id\":390204,\"chapter_name\":\"第三章感觉\",\"content_type\":1}]";
    	JSONArray jsonarray = JSONArray.fromObject(readLog); 
    	List<ActionParam> params = (List<ActionParam>)JSONArray.toCollection(jsonarray, ActionParam.class);
    	System.out.println(IReadUtils.beanToJson(params));*/
    	/*String token = "PZSNK6gRTiSk0JVdcFWH84KjmPGpP4V0lWJQnt%2Bfu1gRJY6T4kuJIwme2s0wMubXeUWcQtRW1%2B6oeHwh5YbTRzVtnUTMCx7Vgw0JryVBNPfwiFob0BYiwXKSaWVMNXXZuU3XZRD8dnXjDfnS41e9fAW%2BpppTkdFeSo6ASo7y830%3D";
    	System.out.println(IReadUtils.getUserIdByTokenWithoutEffective(token));*/
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/block/content", "block_id=160&contents=20&pages=1"));

    //	System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/me/recentReading/delete","book_id=390157&book_id=388284"));
    	
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/me/label/delete","i\",\""));
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://readapi.imread.com/api/me/label/add","id=7"));
    	
    	//System.out.println(HttpRequestUtil.sendGet("http://readapi.imread.com/api/me/label/list", ""));

    	//System.out.println(HttpRequestUtil.sendPost("http://readapi.imread.com/api/bookSheet/collection/delete","sheet_id=1"));
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://readapi.imread.com/api/bookSheet/collection/add","sheet_id=1"));
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/cert/pay","productId=1&spbill_create_ip=192.168.0.1"));
    	
    	//String str= "appid=wx03d6c06f644af38f&bank_type=CFT&cash_fee=1&fee_type=CNY&is_subscribe=N&mch_id=1284269601&nonce_str=SR89M4N7RRX1ZN45BMUJJXCXLNJH789Y&openid=oaTHvsjV1CmmQhotGm6om8jz9Tx4&out_trade_no=1461209668134912&result_code=SUCCESS&return_code=SUCCESS&time_end=20151224143509&total_fee=1&trade_type=APP&transaction_id=1005400512201512242279322024&key=fe8c847e9dfcc86171284abc41849f08";
    //	String sign = MD5Util.MD5Encode(str, "ISO-8859-1").toLowerCase();
    	//System.out.println(sign);
    	//System.out.println(HttpRequestUtil.sendPost("http://readapi.imread.com/api/cert/pay/result", "appid=wx2421b1c4370ec43b&attach=支付测试&bank_type=CFT&fee_type=is_subscribe&mch_id=10000100&nonce_str=5d2b6c2a8db53831f7eda20af46e531c&openid=oUpF8uMEb4qRXf22hE3X68TekukE&out_trade_no=1409811653&result_code=SUCCESS&return_code=SUCCESS&sign=B552ED6B279343CB493C5DD0D78AB241&sub_mch_id=10000100&time_end=20140903131540&total_fee=1&trade_type=JSAPI&transaction_id=1004400740201409030005092168"));
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/cert/pay", "productId=1&spbill_create_ip=192.168.0.1"));
    	
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/me/recentReading", "pages=1&contents=10"));

    	//String token="X5apCLxnWgQLZjt%252Fp%252B3jz536rXGEwLNJpRj%252B9EZo9GoTStmMiugyrUSwohZME4%252FzRZwakwJGV%252F5AtqVCIR544Z5Fm1WxYekzfVvvhmFiSoMr6RV8ROuEG8qDNKZUSbJ0p3QtwajIs53NASjXG6A72Ig5w78HnSjYmB%252FUicx3VIg%253D";
    	
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/auth/balance", "orderno=1448606332266496"));

    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.34:8080/api/group/page", "group_id=1"));

    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/group/page", "group_id=1"));
    	//System.out.println(HttpRequestUtil.sendGet("http://readapi.imread.com/api/book/introduce", "bid=388301"));
    	//System.out.println(HttpRequestUtil.sendGet("http://readapi.imread.com/api/chapter/2/7603/625079/index", "cm=M3540009"));
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/refesh", "group_id=1"));

    	
    	
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/intercut/log", "intercut_id=1152&event=1&show_class=1"));

		//token="fPeZTbAbfB8CdXfBC1%2BPaMBgKictsbXCYPIJHv6fcUOsFDwa1ObCZotNqlijADvamR5RWIj8W8qvh69k3Vifl3ma%2BDJX%2FH226QksYHjkI891a4DWKpSSOGB9z6Ey2trCMJm2HCdi2Yv70nhKolCHL6sGg2G3xoaV%2FekHsiCGZTs%3D";

    	//System.out.println(MD5.getMD5("200136935502351769620151123142214136"+IReadContent.impay_key).toUpperCase());
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/auth/balance", "1=1"));

    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/pay/impay/result", "orderno=1369355023517696&fee=200&reqtime=20151123142214136&others=aa&status=success&sign=CCF16CA9740FDFD71E8148CCF7E2B9E3"));

    	
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/pay", "fee=12&payType=2&spType=1&mobileNum=123456&productName=test&productDesc=test2&productId=1"));
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/auth/edit/info", "user_name=test&user_gender=0&user_birthday=20151117"));
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/bookMark/delete", "mark_id=1417092624491520"));
		
    	
    	//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/bookMark/add", "book_id=1&chapter_id=2&chapter_offset=3"));
		
    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/bookMark/list", "pages=1&contents=10"));

    	//System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/order/list", "pages=1&contents=10"));

/*    	System.out.println(HttpRequestUtil.sendGet("http://192.168.0.252:8080/api/order/list", "pages=1&contents=10&source_user=3&source_id=2"));

    	*/
		//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/order/log", "book_id=1&source_id=2&source_user_id=3&charge_mode=4&charge_fee=5&chapter_id=6"));
		
		/*
		//
		//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.3:8080/api/shelf/add", "bookId=5817&time=1291500000&chapter_id=10&chapter_offset=500&type=3"));

		//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.3:8080/api/shelf/delete", "bookId=5817&type=3"));
		//System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/shelf/update", "bookId=5817&time=1291500000&chapter_id=10&chapter_offset=500&type=3"));
		System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/shelf/delete", "param=1&param=2&type=3"));

		Date date = new Date();
		System.out.println(date);
		System.out.println(date.getTime());*/
		/**/
		/*String str ="[{\"bookId\":5817,\"time\":1291500000,\"chapter_id\":10,\"chapter_offset\":500,\"type\":3}]";
		System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/shelf/add", "param="+str));*/
		
		/**//*String str ="[{\"bookId\":5817,\"time\":14915000000,\"chapter_id\":10,\"chapter_offset\":500,\"type\":3}]";

		System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/shelf/update", "param="+str));
*/
		/*Date date = new Date();
		System.out.println(date);
		System.out.println(date.getTime());*/
		/*String str = "[{\"bookId\":5817,\"type\":3}]";
		System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/shelf/delete", "param="+str));*/
		/*String str ="[{\"bookId\":5817,\"time\":1291500000,\"chapter_offset\":500,\"type\":3}]";
		System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/shelf/update", "param="+str));
		*/
		/*String str="20151103110609";
		System.out.println(DateUtil.StrToDate(str, "yyyyMMddHHmmss"));*/
		//System.out.println(HttpRequestUtil.sendGet("http://api.imread.com/v2/api/me", "token=Eg6Het5DDRE730261D%2FjsctFn6CmZBjGZpFII5Na6jKesn9eT9vzFBuVxvcvRlrzPccfR6w51fZgMgJFLnmqQ5gHsIxaSGvaUniJKtxoJXyYLjEFDrxfQ28dQHwJfx7SAqTvGyOuvyOf3JBqtDRbTUCjWHPp1j42tmgTveDd%2FiA%3D"));
		/*String str ="[]";

		System.out.println(HttpRequestUtil.sendPost("http://192.168.0.252:8080/api/shelf/synchronous", "param="+str));*/
	/*	for(int a=0;a<50;a++)
			for(int b=0;b<30;b++)
				for(int c=0;c<30;c++)
					for(int d=0;d<30;d++)
						for(int e=0;e<30;e++)
							for(int f=1;f<30;f++)
								for(int g=0;g<30;g++)
									for(int h=0;h<30;h++)
										math(a,b,c,d,e,f,g,h);*/
	}


}
